﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace CVsharp.Jquery.DWZ
{
    public class Pagination
    {
        #region 分页变量，与UI绑定

        public int numPerPage = 20;
        /// <summary>
        /// 每页显示的条数
        /// </summary>
        public int NumPerPage
        {
            get { return numPerPage; }
            set { numPerPage = value; }
        }
        private int pageNumShown = 10;
        /// <summary>
        /// 页数导航的个数
        /// </summary>
        public int PageNumShown
        {
            get { return pageNumShown; }
            set { pageNumShown = value; }
        }

        public int pageNum = 1;
        /// <summary>
        /// 当前显示的页数
        /// </summary>
        public int PageNum
        {
            get { return pageNum; }
            set { pageNum = value; }
        }

        public int totalCount = 20;
        /// <summary>
        /// 总条数
        /// </summary>
        public int TotalCount
        {
            get { return totalCount; }
            set { totalCount = value; }
        }

        /// <summary>
        /// where语句，不加where与空格
        /// </summary>
        public string Keywords { get; set; }

        /// <summary>
        /// 排序关键字
        /// </summary>
        public string OrderField { get; set; }

        private int currentPage = 1;
        public int CurrentPage
        {
            get { return currentPage; }
            set { currentPage = value; }
        }

        #endregion
    }
}
